let debounceTime = 0;
//函数节流
export const throttle = (fun: Function, time = 0) => {
  const now = Date.now();
  if (now - time > debounceTime) {
    debounceTime = now;
    fun();
  }
};